ostbuild: Show cwd on failure
authorColin Walters <walters@verbum.org>
Thu, 19 Jan 2012 21:41:59 +0000 (16:41 -0500)
committerColin Walters <walters@verbum.org>
Thu, 19 Jan 2012 21:41:59 +0000 (16:41 -0500)
This is helpful for disambiguation.

src/ostbuild/pyostbuild/subprocess_helpers.py

index 66e365beda76021ed38fcf1872e35428feb8a1d9..0d1ca8d6098da01fa8d1ca0c4dbf53ad3849e127 100755 (executable)
@@ -63,7 +63,8 @@ def run_sync_get_output(args, cwd=None, env=None, stdout=None, stderr=None, none
     else:
         logfn = None
     if logfn is not None:
-        logfn("cmd '%s' exited with code %d, %d bytes of output" % (subprocess.list2cmdline(args), proc.returncode, len(output)))
+        logfn("cmd '%s' (cwd=%s) exited with code %d, %d bytes of output" % (subprocess.list2cmdline(args),
+                                                                             cwd, proc.returncode, len(output)))
     if proc.returncode == 0:
         return output
     return None